<template>
<h1>事件绑定练习</h1>
  <button @click="f()">点击</button>
  <button v-on:click="f()">点击1</button>

  <input type="text" @keydown.enter="ent()">
</template>

<script setup>
const f = ()=>{
  alert('点击了')
}

const ent = ()=>{
  alert("按回车进行了绑定回车事件")
}
</script>

<style scoped>

</style>